<?php
namespace Rootadmin\Controller;
use Think\Controller;
class AdminController extends Controller {
	protected function _initialize(){
		$this->checkLogin();
	}
	private function checkLogin(){
	    $userid = session("userid");
	    $name = session("name");
		if(empty($userid) || empty($name)){
			header("location:/Rootadmin/login/index");
			die();
		}
		$this->assign("name",$name);
	}
}
?>